import React, {Component} from 'react';
import {BrowserRouter, Route, Switch} from 'react-router-dom'
import './App.css';
import configStore from './redux/store/index'
import { Provider } from 'react-redux'
import Login from './pages/login/login'
import Admin from './pages/admin'

const store = configStore()

class App extends Component{
    render() {
        return(
            <Provider store={store}>
                <BrowserRouter>
                    <Switch>
                        <Route path='/login' component={Login}></Route>
                        <Route path='/' component={Admin}></Route>
                    </Switch>
                </BrowserRouter>
            </Provider>
            )
        }
}

export default App;
